package com.restlet.spike.server;

import org.restlet.Application;
import org.restlet.Component;
import org.restlet.data.Protocol;

public class ServerRunner {
    public static void main(String[] args) throws Exception {

        // Create a component
        Component component = new Component();
        component.getServers().add(Protocol.HTTP, 8183);
        component.getClients().add(Protocol.FILE);

        // Create an application
        Application application = new FirstApplication(component);

        // Attach the application to the component and start it
        component.getDefaultHost().attach("/app1", application);
        component.start();
    }

}